<:!:/>

@file c.stats.html
@author Alejandro Dario Simi
@date $Date: 2013-05-19 06:39:24 +0000 (Sun, 19 May 2013) $

$Id: c.stats.html 65 2013-05-19 06:39:24Z daemonraco@gmail.com $
$URL: http://wcomix.googlecode.com/svn/tags/wcomix-1.0.0.1/themes/default/templates/contents/c.stats.html $

<::/><script type="text/javascript" src="<:VAR:/>JQPLOT-URI<::/>/jquery.jqplot.min.js"></script>
<script type="text/javascript" src="<:VAR:/>JQPLOT-URI<::/>/plugins/jqplot.barRenderer.min.js"></script>
<script type="text/javascript" src="<:VAR:/>JQPLOT-URI<::/>/plugins/jqplot.categoryAxisRenderer.min.js"></script>
<script type="text/javascript" src="<:VAR:/>JQPLOT-URI<::/>/plugins/jqplot.pieRenderer.min.js"></script>
<script type="text/javascript" src="<:VAR:/>JQPLOT-URI<::/>/plugins/jqplot.pointLabels.min.js"></script>
<script type="text/javascript">$("head").append('<link rel="stylesheet" type="text/css" href="<:VAR:/>JQPLOT-URI<::/>/jquery.jqplot.min.css"/>');</script>

<style type="text/css">
	#SpecialsSection {
		margin-left: auto;
		margin-right: auto;
		width: 800px;
	}
	#SpecialsSection div {
		display: block;
	}
	#SpecialsSection div.Title {
		font-size: large;
		font-weight: bold;
	}
	#SpecialsSection div.Chart {
		display: table-cell;
		height: 400px;
		width: 400px;
	}
</style>
<div id="SpecialsSection">
	<div class="Title">Special Tags Weight</div>
	<div class="Help">
		<p>This two pie charts show the weihgt of special tags over
		the rest on this group.</p>
		<p>The left chart gives an idea of how many comics are not tagged
		and how many have just a few tags.</p>
		<p>The right chart show which special is heavier than the others.</p>
	</div>
	<div id="SpecialsFull" class="Chart"></div><div id="Specials" class="Chart"></div>
</div>

<style type="text/css">
	#TimesSection {
		margin-left: auto;
		margin-right: auto;
		width: 800px;
	}
	#TimesSection div {
		display: block;
	}
	#TimesSection div.Title {
		font-size: large;
		font-weight: bold;
	}
	#TimesSection div.Chart {
		height: <:VAR:/>elapsed-height<::/>px;
	}
</style>
<div id="TimesSection">
	<div class="Title">Last <:VAR:/>stats-max-time<::/> days elapsed time average</div>
	<div class="Help">
		<p>This chart shows the top <:VAR:/>elapsed-limit<::/> of
		the slowest pages. This values are the average of milliseconds
		these pages took before being sent to the user.</p>
	</div>
	<div id="Times" class="Chart"></div>
</div>

<style type="text/css">
	#FactorsSection {
		margin-left: auto;
		margin-right: auto;
		width: 800px;
	}
	#FactorsSection div {
		display: block;
	}
	#FactorsSection div.Title {
		font-size: large;
		font-weight: bold;
	}
	#FactorsSection div.Chart {
		height: <:VAR:/>factors-height<::/>px;
	}
</style>
<div id="FactorsSection">
	<div class="Title">Last <:VAR:/>stats-max-time<::/> days relevance</div>
	<div class="Help">
		<p>This chart shows the top <:VAR:/>factors-limit<::/> of
		pages that may be causing slow responses. This is a proportion
		beween average elapsed time of page and hits it had.</p>
	</div>
	<div id="Factors" class="Chart"></div>
</div>

<script type="text/javascript">
	$(document).ready(function() {
		$.jqplot.config.enablePlugins = true;

		var elapsedNames = [<:VAR:/>elapsed-names<::/>];
		var elapsedTimes = [<:VAR:/>elapsed-times<::/>];

		TimesPlot = $.jqplot("Times", [elapsedTimes], {
			seriesDefaults: {
				renderer: $.jqplot.BarRenderer,
				pointLabels: {
					show: true
				},
				rendererOptions: {
					barDirection: "horizontal",
					highlightMouseDown: true
				}
			},
			axes: {
				yaxis: {
					renderer: $.jqplot.CategoryAxisRenderer,
					ticks: elapsedNames
				}
			},
			highlighter: {
				show: false
			}
		});

		var factorsNames = [<:VAR:/>factors-names<::/>];
		var factorsValues = [<:VAR:/>factors-values<::/>];

		factorsPlot = $.jqplot("Factors", [factorsValues], {
			seriesDefaults: {
				renderer: $.jqplot.BarRenderer,
				pointLabels: {
					show: true
				},
				rendererOptions: {
					barDirection: "horizontal",
					highlightMouseDown: true
				}
			},
			axes: {
				yaxis: {
					renderer: $.jqplot.CategoryAxisRenderer,
					ticks: factorsNames
				}
			},
			highlighter: {
				show: false
			}
		});

		var SpecialTagsData = [<:VAR:/>tags-specials<::/>];

		var SpecialPlot = jQuery.jqplot("Specials", [SpecialTagsData], {
			seriesDefaults: {
				renderer: jQuery.jqplot.PieRenderer,
				rendererOptions: {
					// Turn off filling of slices.
					fill: false,
					showDataLabels: true,
					// Add a margin to seperate the slices.
					sliceMargin: 4,
					// stroke the slices with a little thicker line.
					lineWidth: 5
				}
			},
			legend: {
				show: true,
				location: 'e'
			}
		});

		var SpecialFullData = [<:VAR:/>tags-specials-full<::/>];

		var SpecialFullPlot = jQuery.jqplot("SpecialsFull", [SpecialFullData], {
			seriesDefaults: {
				renderer: jQuery.jqplot.PieRenderer,
				rendererOptions: {
					// Turn off filling of slices.
					fill: false,
					showDataLabels: true,
					// Add a margin to seperate the slices.
					sliceMargin: 4,
					// stroke the slices with a little thicker line.
					lineWidth: 5
				}
			},
			legend: {
				show: true,
				location: 'e'
			}
		});
	});
</script>